Skip to content

src: add initial shadow realm support#42869

Merged
aduh95 merged 1 commit into
nodejs:masterfrom
legendecas:shadow-realm/constructor
May 2, 2022
Merged

src: add initial shadow realm support#42869
aduh95 merged 1 commit into
nodejs:masterfrom
legendecas:shadow-realm/constructor

Conversation

@legendecas

Copy link
Copy Markdown
Member

Add initial shadow realm support behind an off-by-default flag--experimental-shadow-realm.

This enables the ShadowRealm constructor and ShadowRealm.prototype.evaluate support in Node.js.

Refs: #42528

@nodejs-github-bot

Copy link
Copy Markdown
Collaborator

Review requested:

  • @nodejs/gyp

@nodejs-github-bot nodejs-github-bot added c++ Issues and PRs that require attention from people who are familiar with C++. lib / src Issues and PRs related to general changes in the lib or src directory. needs-ci PRs that need a full CI run. labels Apr 25, 2022
@legendecas legendecas force-pushed the shadow-realm/constructor branch from 30dc744 to 8004257 Compare April 25, 2022 16:43
@legendecas legendecas marked this pull request as ready for review April 25, 2022 16:44
@legendecas legendecas force-pushed the shadow-realm/constructor branch from 8004257 to 4990c42 Compare April 25, 2022 16:51
Comment thread doc/api/cli.md
@aduh95

aduh95 commented Apr 26, 2022

Copy link
Copy Markdown
Contributor

Can you add an entry to lib/.eslintrc.yml in the same vein as SharedArrayBuffer

node/lib/.eslintrc.yaml

Lines 90 to 93 in 560cbc5

# SharedArrayBuffer is not available in primordials because it can be
# disabled with --no-harmony-sharedarraybuffer CLI flag.
- name: SharedArrayBuffer
message: Use `const { SharedArrayBuffer } = globalThis;` instead of the global.

Comment thread test/parallel/test-shadow-realm.js Outdated
@legendecas legendecas force-pushed the shadow-realm/constructor branch from 4990c42 to ad41c28 Compare April 26, 2022 15:46
@aduh95 aduh95 added author ready PRs that have at least one approval, no pending requests for changes, and a CI started. request-ci Add this label to start a Jenkins CI on a PR. semver-minor PRs that contain new features and should be released in the next minor version. dont-land-on-v12.x labels Apr 26, 2022
@github-actions github-actions Bot removed the request-ci Add this label to start a Jenkins CI on a PR. label Apr 26, 2022
@nodejs-github-bot

Copy link
Copy Markdown
Collaborator

@legendecas legendecas added the request-ci Add this label to start a Jenkins CI on a PR. label Apr 27, 2022
@github-actions github-actions Bot removed the request-ci Add this label to start a Jenkins CI on a PR. label Apr 27, 2022
@nodejs-github-bot

Copy link
Copy Markdown
Collaborator

Comment thread doc/api/cli.md Outdated
Comment thread node.gyp
@legendecas legendecas force-pushed the shadow-realm/constructor branch from ad41c28 to c1f9e4c Compare April 27, 2022 14:58
@legendecas legendecas added the request-ci Add this label to start a Jenkins CI on a PR. label Apr 28, 2022
@sepehrst

Copy link
Copy Markdown

The CLI option --experimental-shadow-realm is not reflected in node --help output. Is that intentional?

@danielleadams danielleadams mentioned this pull request Jun 11, 2022
@ruyadorno

Copy link
Copy Markdown
Member

@aduh95 is it intentional to have marked this PR as backport-blocked-v18.x ?

@joyeecheung

Copy link
Copy Markdown
Member

Ping @Adu95 is there a reason that this should be marked backport-blocked-v18.x? Would be better if we backport this to avoid conflicts with other Realm refactoring PRs.

@aduh95

aduh95 commented Oct 14, 2022

Copy link
Copy Markdown
Contributor

Sorry I missed the original ping, IIRC it was due to an incompatible version of V8 on v18.x, maybe it's ready to be backported now, it's worth trying.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

author ready PRs that have at least one approval, no pending requests for changes, and a CI started. c++ Issues and PRs that require attention from people who are familiar with C++. lib / src Issues and PRs related to general changes in the lib or src directory. needs-ci PRs that need a full CI run. semver-minor PRs that contain new features and should be released in the next minor version.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

9 participants